package com.code.AZPlan.model.po;

import com.code.commons.model.po.BasePO;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.hibernate.validator.constraints.Length;

import javax.persistence.Id;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.math.BigDecimal;

/**
 * AZ计划资金划转PO及持久层对象
 *
 * @author tangyifei
 * @since 2019年12月31日14:34:55
 */
@ApiModel("AZ计划资金划转PO及持久层对象")
@Builder
@AllArgsConstructor
@NoArgsConstructor
@Data
public class MoneyTransferRecord extends BasePO<String> {

    private static final long serialVersionUID = 820865988866545205L;

    @ApiModelProperty(value = "主键", example = "1")
    @Id
    @Length(min = 1, max = 64)
    private String id;

    @ApiModelProperty(value = "用户主键", example = "1")
    @NotBlank(message = "用户主键不能为空")
    @Length(min = 1, max = 64)
    private String userId;

    @ApiModelProperty(value = "1表示从钱包划转到AZ计划   2表示从AZ计划划转到钱包", example = "1")
    @NotNull(message = "划转类型不能为空")
    private Integer transferType;

    @ApiModelProperty(value = "币种类型", example = "XWC")
    @NotBlank(message = "币种类型不能为空")
    private String coinType;

    @ApiModelProperty(value = "币种地址", example = "XWC1212")
    private String coinAddress;

    @ApiModelProperty(value = "划转金额（划转数量）", example = "1")
    @NotNull(message = "划转金额（划转数量）不能为空")
    private BigDecimal amount;

    @ApiModelProperty(value = "交易密码", example = "1")
    @NotBlank(message = "交易密码不能为空")
    private String tranPwd;

    @ApiModelProperty(value = "用户XWC钱包账户版本号", example = "1")
    private Integer xwcCoinBalanceVersion;

    @ApiModelProperty(value = "用户BTC钱包账户版本号", example = "1")
    private Integer btcCoinBalanceVersion;

    @ApiModelProperty(value = "用户USDT钱包账户版本号", example = "1")
    private Integer usdtCoinBalanceVersion;

    @ApiModelProperty(value = "资金划转版本号", example = "1")
    @NotNull(message = "资金划转版本号不能为空")
    private Integer version;

    @ApiModelProperty(value = "BTC相关AZ钱包的版本号", example = "1")
    private Integer btcAZPlanWalletVersion;

    @ApiModelProperty(value = "XWC相关AZ钱包的版本号", example = "1")
    private Integer xwcAZPlanWalletVersion;

    @ApiModelProperty(value = "用户余额", example = "1")
    private BigDecimal coinBalance;

    @ApiModelProperty(value = "XWC相关的AZ计划钱包的余额", example = "1")
    private BigDecimal xwcAZPlanBalance;

    @ApiModelProperty(value = "BTC相关的AZ计划钱包的余额", example = "1")
    private BigDecimal btcAZPlanBalance;

}
